﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ReceiptInquiryList.aspx.cs" EnableViewState="false" EnableEventValidation="false" Inherits="WMS6.Web.Inbound.ReceiptInquiryList" meta:resourcekey="Page" %>
<%@ PreviousPageType VirtualPath="~/Inbound/ReceiptInquiryQuery.aspx" %>
<%@ Register src="../UserControls/Pager.ascx" tagname="Pager" tagprefix="uc1" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head1" runat="server">
    <title>ReceiptInquiryList</title>
    <link href="../style/zh/1/css.css" type="text/css" rel="Stylesheet" id="mycss" />
    <link href="../Css/style.css" type="text/css" rel="stylesheet" />
    <script src="../Js/jquery.js" type="text/javascript"></script>
    <script src="../Js/jquery.simplemodal.js" type="text/javascript"></script>    
    <script src="../Js/checkbox.js" type="text/javascript"></script>
    <script src="../Js/util.js" type="text/javascript"></script>
    <script src="../Js/InitPage.js" type="text/javascript"></script>
    
    <script type="text/javascript">
        //初始化页面
        window.onload = function(){
            initListPage();
        }
        
        function returnSearch()
        {
            var from = document.getElementById("hdnFrom").value;
            if(from != "")
            {
                window.location.href = "ReceiptInquiryQuery.aspx";
            }
            else
            {
                window.history.go(-1);
            }
        }
    </script>
</head>
<body>
    <form id="F4042" runat="server">
    <div>
        <asp:ScriptManager ID="ScriptManager1" runat="server" />
        
        <div id="div_List_top">
            <table>
                <tr>
                    <td valign="bottom"><asp:Label ID="lblReceiptInquiryList" runat="server" CssClass="label_header"  Text="入库查询列表" meta:resourcekey="lblUom"></asp:Label></td>
                    <td><asp:Button ID="btnNew" runat="server" CssClass="button" Enabled="False" 
                            Text="<%$Resources:ButtonResource,btnNew%>"  Visible="False"  /></td>
                    <td><asp:Button ID="btnEdit" runat="server" CssClass="button" Enabled="False" 
                            Text="<%$Resources:ButtonResource,btnEdit%>"  Visible="False" /></td>
                    <td>
                    <asp:Button ID="btnDelete" runat="server" CssClass="button" Enabled="False" 
                            Text="<%$Resources:ButtonResource,btnDelete%>" Visible="False" />
                            
                            </td>
                    <td><asp:Button ID="btnRefresh" runat="server" CssClass="button" Enabled="False" 
                            Text="<%$Resources:ButtonResource,btnRefresh%>"   /></td>
                    <td><asp:Button ID="btnAction" runat="server" CssClass="button" Enabled="False" 
                            Text="<%$Resources:ButtonResource,btnAction%>" Visible="False"   /></td>
                    <td><asp:Button ID="btnReport" runat="server" CssClass="button" Enabled="False" 
                            Text="报告"  Visible="False"   /></td>
                </tr>
            </table>
        </div>
        <div class="blank8">
        </div>
        
        <asp:UpdatePanel ID="up1" runat="server">
            <ContentTemplate>
                <div id="div_List">
                <div id="div_List_msg">
                        <asp:Label ID="lblMsg" runat="server" CssClass="label_message"></asp:Label>
                    </div>
                    <asp:GridView ID="gvReceipt" runat="server" AutoGenerateColumns="False" AllowSorting="True" 
                            CssClass="gridview" onrowdatabound="gvReceipt_RowDataBound" oninit="gvReceipt_Init" 
                        onsorting="gvReceipt_Sorting" DataKeyNames="RECEIPT_ID" PageSize="20" 
                        Width="3600px" meta:resourcekey="gvReceipt" >
                            <FooterStyle CssClass="GridViewFooterStyle" />
                            <RowStyle CssClass="GridViewRowStyle" />
                            <HeaderStyle CssClass="GridViewHeaderStyle" />
                            <AlternatingRowStyle CssClass="GridViewAlternatingRowStyle" />
                            <Columns>                    
                                <asp:BoundField HeaderText="序号" FooterText="序号" 
                                    meta:resourcekey="No" ><ItemStyle CssClass="GridViewRowWidth_40" /></asp:BoundField>
                                <asp:TemplateField meta:resourcekey="TemplateField" >
                                    <HeaderTemplate>
                                        <img src="../Images/gvSettingpic.gif" id="img01" class="gvSettingImg" onclick="gvUserSetting('4042','gvReceipt');" onmouseover="showGVUserSettingAlt(this);" alt="customize list" />
                                        <asp:CheckBox ID="CheckBox1" runat="server" 
                                            onclick="selectAll(this,'gvReceipt');" meta:resourcekey="CheckBox1" />
                                    </HeaderTemplate>
                                    <ItemTemplate>
                                        <asp:CheckBox ID="chbSelect" runat="server" 
                                            meta:resourcekey="chbSelect" />
                                    </ItemTemplate>
                                    <FooterTemplate>
                                        <asp:CheckBox ID="CheckBox2" runat="server" 
                                            onclick="selectAll(this,'gvReceipt');" meta:resourcekey="CheckBox2" />
                                    </FooterTemplate>
                                    <HeaderStyle HorizontalAlign="Center" CssClass="GridViewRowWidth_50" />
                                    <ItemStyle HorizontalAlign="Center" CssClass="GridViewRowWidth_50" />
                                </asp:TemplateField>
                                <asp:BoundField DataField="OWNER_ID" HeaderText="货主代码" FooterText="货主代码" 
                                    SortExpression="OWNER_ID" meta:resourcekey="OWNER_ID">
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:BoundField>
                                <asp:TemplateField HeaderText="入库通知单号" FooterText="入库通知单号" 
                                    SortExpression="RECEIPT_ID" meta:resourcekey="RECEIPT_ID">
                                    <ItemTemplate>
                                        <asp:HyperLink ID="HyperLink1" runat="server" Text='<%# Eval("RECEIPT_ID") %>' NavigateUrl='<%# FormatUrl("~/Inbound/ReceiptInquiry.aspx?from=list&ID={0}",Eval("RECEIPT_ID").ToString()) %>'
                                            Target="_self" CssClass="hyperlink" meta:resourcekey="HyperLink1"></asp:HyperLink>
                                    </ItemTemplate>
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:TemplateField>
                                <asp:BoundField DataField="PO_ID" HeaderText="采购订单号" FooterText="采购订单号" 
                                    SortExpression="PO_ID" meta:resourcekey="PO_ID">
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:BoundField>
                                <asp:BoundField DataField="EXTERNAL_RECEIPT_ID" HeaderText="外部订单号" FooterText="外部订单号"
                                    SortExpression="EXTERNAL_RECEIPT_ID" meta:resourcekey="EXTERNAL_RECEIPT_ID">
                                    <ItemStyle CssClass="GridViewRowWidth_150" />
                                </asp:BoundField>
                                <asp:BoundField DataField="STATUS_D" HeaderText="状态" FooterText="状态" SortExpression="STATUS_D"
                                    meta:resourcekey="STATUS_D">
                                    <ItemStyle CssClass="GridViewRowWidth_150" />
                                </asp:BoundField>
                                <asp:BoundField DataField="RECEIPT_TYPE_D" HeaderText="类型" FooterText="类型" SortExpression="RECEIPT_TYPE_D"
                                    meta:resourcekey="RECEIPT_TYPE_D">
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:BoundField>
                                <asp:TemplateField FooterText="收货日期" HeaderText="收货日期" 
                                    SortExpression="RECEIPT_DATE" meta:resourcekey="RECEIPT_DATE">
                                    <ItemTemplate>
                                        <asp:Label ID="lblActualReceiptDate" runat="server"
                                         Text='<%# GetPreferenceShortDate(Eval("RECEIPT_DATE").ToString()) %>' 
                                            meta:resourcekey="lblActualReceiptDate"></asp:Label>
                                    </ItemTemplate>
                                    <ItemStyle CssClass="GridViewRowWidth_150" />
                                </asp:TemplateField>
                                <asp:BoundField DataField="RECEIPT_LINE_ID" HeaderText="行号" FooterText="行号" 
                                    SortExpression="RECEIPT_LINE_ID" meta:resourcekey="RECEIPT_LINE_ID">
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:BoundField>
                                <asp:BoundField DataField="SKU_ID" HeaderText="货品代码" FooterText="货品代码"
                                    SortExpression="SKU_ID" meta:resourcekey="SKU_ID">
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:BoundField>
                                <asp:TemplateField FooterText="货品描述" HeaderText="货品描述" SortExpression="DESCR" 
                                    meta:resourcekey="DESCR" >
                                    <ItemTemplate>
                                        <asp:Label ID="lblSkuDescr" runat="server" 
                                            Text='<%# Eval("DESCR").ToString() %>' meta:resourcekey="lblSkuDescr"></asp:Label>
                                    </ItemTemplate>
                                    <ItemStyle CssClass="GridViewRowWidth_200" />       
                                 </asp:TemplateField>
                                 
                                 <asp:BoundField DataField="SKU_CLASS_ID" HeaderText="货品分类代码" FooterText="货品分类代码"
                                    SortExpression="SKU_CLASS_ID" meta:resourcekey="SKU_CLASS_ID">
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:BoundField>
                                 
                                 <asp:BoundField DataField="SKU_CLASS_DESCR" HeaderText="货品分类名称" FooterText="货品分类名称"
                                    SortExpression="SKU_CLASS_DESCR" meta:resourcekey="SKU_CLASS_DESCR">
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:BoundField>
                                <asp:BoundField DataField="VENDOR_ID" HeaderText="供应商代码" FooterText="供应商代码"
                                    SortExpression="VENDOR_ID" meta:resourcekey="VENDOR_ID">
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:BoundField>
                                <asp:BoundField DataField="VENDOR_NAME" HeaderText="供应商名称" FooterText="供应商名称"
                                    SortExpression="VENDOR_NAME" meta:resourcekey="VENDOR_NAME">
                                    <ItemStyle CssClass="GridViewRowWidth_200" />
                                </asp:BoundField>
                                <asp:BoundField DataField="EXTERNAL_LOT" HeaderText="外部批号" FooterText="外部批号"
                                    SortExpression="EXTERNAL_LOT" meta:resourcekey="EXTERNAL_LOT">
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:BoundField>
                                <asp:TemplateField FooterText="预期量" HeaderText="预期量" 
                                    SortExpression="EXPECTED_QTY" meta:resourcekey="EXPECTED_QTY">
                                    <ItemTemplate>
                                        <asp:Label ID="lblExpectedQty" runat="server" 
                                            Text='<%# GetPreferenceDigit(Eval("EXPECTED_QTY").ToString()) %>' 
                                            meta:resourcekey="lblExpectedQty"></asp:Label>
                                    </ItemTemplate>
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:TemplateField>
                                <asp:TemplateField FooterText="接收量" HeaderText="接收量" 
                                    SortExpression="RECEIVED_QTY" meta:resourcekey="RECEIVED_QTY">
                                    <ItemTemplate>
                                        <asp:Label ID="lblReceivedQty" runat="server" 
                                            Text='<%# GetPreferenceDigit(Eval("RECEIVED_QTY").ToString()) %>' 
                                            meta:resourcekey="lblReceivedQty"></asp:Label>
                                    </ItemTemplate>
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:TemplateField>   
                                <asp:TemplateField FooterText="预上架数量" HeaderText="预上架数量" 
                                    SortExpression="PA_PENDING_QTY" meta:resourcekey="PA_PENDING_QTY">
                                    <ItemTemplate>
                                        <asp:Label ID="lblPaPendingQty" runat="server" 
                                            Text='<%# GetPreferenceDigit(Eval("PA_PENDING_QTY").ToString()) %>' 
                                            meta:resourcekey="lblPaPendingQty"></asp:Label>
                                    </ItemTemplate>
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:TemplateField> 
                                <asp:TemplateField FooterText="差异量" HeaderText="差异量" SortExpression="DIFF_QTY" 
                                    meta:resourcekey="DIFF_QTY">
                                    <ItemTemplate>
                                        <asp:Label ID="lblDiffQty" runat="server" 
                                            Text='<%# GetPreferenceDigit(Eval("DIFF_QTY").ToString()) %>' 
                                            meta:resourcekey="lblDiffQty"></asp:Label>
                                    </ItemTemplate>
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:TemplateField>   
                                <asp:TemplateField FooterText="已上架数量" HeaderText="已上架数量" 
                                    SortExpression="PA_COMPLETED_QTY" meta:resourcekey="PA_COMPLETED_QTY">
                                    <ItemTemplate>
                                        <asp:Label ID="lblPaCompletedQty" runat="server" 
                                            Text='<%# GetPreferenceDigit(Eval("PA_COMPLETED_QTY").ToString()) %>' 
                                            meta:resourcekey="lblPaCompletedQty"></asp:Label>
                                    </ItemTemplate>
                                    <ItemStyle CssClass="GridViewRowWidth_150" />
                                </asp:TemplateField>   
                                <asp:BoundField DataField="SKU_PROPERTY" HeaderText="货品属性" FooterText="货品属性" 
                                    SortExpression="SKU_PROPERTY" meta:resourcekey="SKU_PROPERTY">
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:BoundField>    
                                <asp:TemplateField FooterText="总重量" HeaderText="总重量" SortExpression="TOTAL_WGT" 
                                    meta:resourcekey="TOTAL_WGT">
                                    <ItemTemplate>
                                        <asp:Label ID="lblTotalWgt" runat="server" 
                                            Text='<%# GetPreferenceDigit(Eval("TOTAL_WGT").ToString()) %>' 
                                            meta:resourcekey="lblTotalWgt"></asp:Label>
                                    </ItemTemplate>
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:TemplateField>        
                                <asp:TemplateField FooterText="总毛重" HeaderText="总毛重" 
                                    SortExpression="TOTAL_GROSS_WGT" meta:resourcekey="TOTAL_GROSS_WGT">
                                    <ItemTemplate>
                                        <asp:Label ID="lblTotalGrossWgt" runat="server" 
                                            Text='<%# GetPreferenceDigit(Eval("TOTAL_GROSS_WGT").ToString()) %>' 
                                            meta:resourcekey="lblTotalGrossWgt"></asp:Label>
                                    </ItemTemplate>
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:TemplateField>        
                                <asp:TemplateField FooterText="总体积" HeaderText="总体积" 
                                    SortExpression="TOTAL_CUBE" meta:resourcekey="TOTAL_CUBE">
                                    <ItemTemplate>
                                        <asp:Label ID="lblTotalCube" runat="server" 
                                            Text='<%# GetPreferenceDigit(Eval("TOTAL_CUBE").ToString()) %>' 
                                            meta:resourcekey="lblTotalCube"></asp:Label>
                                    </ItemTemplate>
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:TemplateField>                          
                                <asp:BoundField DataField="RMA" HeaderText="RMA" FooterText="RMA" 
                                    SortExpression="RMA" meta:resourcekey="RMA">
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:BoundField>
                                <asp:BoundField DataField="LPN_ID" HeaderText="LPN" FooterText="LPN" 
                                    SortExpression="LPN_ID" meta:resourcekey="LPN_ID">
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:BoundField>
                                <asp:BoundField DataField="TO_LOT" HeaderText="批次号" FooterText="批次号" 
                                    SortExpression="TO_LOT" meta:resourcekey="TO_LOT">
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:BoundField>
                                <asp:BoundField DataField="REMARK" HeaderText="备注" FooterText="备注" 
                                    SortExpression="REMARK" meta:resourcekey="REMARK">
                                    <ItemStyle CssClass="GridViewRowWidth_100" />
                                </asp:BoundField>
                            </Columns>
                    </asp:GridView>
                    </div>        
                    <div id="div_pager">
                        <uc1:Pager ID="PagerFooter" runat="server"  OnFirst="btnFirst_Click" OnPrevious="btnPrevious_Click" OnNext="btnNext_Click" OnLast="btnLast_Click" OnGoTo="GoTo_Click"/>
                    </div>
            </ContentTemplate>
            <Triggers>
            <asp:AsyncPostBackTrigger ControlID="btnEdit" EventName="Click" />
            <asp:AsyncPostBackTrigger ControlID="btnDelete" EventName="Click" />
            <asp:AsyncPostBackTrigger ControlID="btnAction" EventName="Click" />
            <asp:AsyncPostBackTrigger ControlID="btnList" EventName="Click" />
        </Triggers>
        </asp:UpdatePanel>    
        
        <div id="div_List_bottom">
            <table>
                <tr>
                    <td>
                        <asp:Button ID="btnSearch" runat="server" Text="<%$Resources:ButtonResource,btnNewSearch%>" CssClass="button" Enabled="False" 
                            OnClientClick="javascript:window.location.href='ReceiptInquiryQuery.aspx';return false;" 
                              />
                    </td>
                    <td>
                        <asp:Button ID="btnReSearch" runat="server" Text="<%$Resources:ButtonResource,btnReSearch%>" CssClass="button" Enabled="False" 
                            OnClientClick="javascript:returnSearch();return false;" 
                             />
                    </td>
                    <td>
                        <asp:Button ID="btnList" runat="server" Text="<%$Resources:ButtonResource,btnList%>" CssClass="button" Enabled="False" 
                           onclick="btnList_Click"   />
                    </td>
                    <td>
                        <asp:Button ID="btnExport" runat="server" Text="<%$Resources:ButtonResource,btnExport%>" CssClass="button" Enabled="False" 
                             onclick="btnExport_Click"     />
                    </td>
                </tr>
            </table>
        </div>      
    </div>
    <input type="hidden" id="hdnFrom" runat="server" />
    <input type="hidden" id="hdnActionID" runat="server" />
        
    </form>
</body>
</html>
